The present invention relates to a data processor for interpreting and executing an instruction having a tag indicating a data type and an instruction having no tag.
A Neumann type general purpose data processor (which will be called a "computer") has a macro instruction (which will be hereinafter simply called an "instruction") intrinsic thereto, and the instruction is usually composed of an operation code indicating the kind of operation and an operand designator indicating the location of an operand to be operated on. And, the operand designating method is called an "addressing mode", for which a variety of methods have been proposed Those computers are commonly featured by the fact that the type of data to be handled by an instruction is uniquely determined by the operation code. For example, even data existing in the same operand is computed for a fixed point instruction by deeming the data as an integer and for a letter instruction by deeming the data as a letter code.
In a computer dedicated to prolog, as described in "Hardware Development of Personal Sequential Type Inference Machine PSI" in the Proceedings of the Logic Programming Conference '84, on the contrary, a specified bit of each data is assigned a tag so that this tag is given information about the data type of that data. In operation, the kind of computation is changed while the data type is judged by examining the tag. This tag architecture can efficiently execute a symbol processing language.
The two kinds of computer architectures described above are independent of and contradictory to each other. In an application such as an intelligence engineering, however, both the numerical processing, which is the strong point of the former, and the non-numerical processing, which is the strong point of the latter, are required and so that there is a need for a computer which can execute either of these two processings. On the other hand, the advent of a logical data processor has been desired which is suitable for processing tag parts added to data in order to identify attributes of that data upon execution of such a predicate logical language as prolog.
Although a procedure-oriented language system as is represented by "FORTRAN" has its procedure and data separated, a logical language such as prolog is processed by evaluating data. In order to efficiently execute such logical language, therefore, there are attached to all of the data fields, i.e., tag parts, for indicating the attributes (e.g., variables, constants or structures) of the data. Thanks to the concentration of the data attributes at the tag parts, the language processing system is able to perform processing by evaluating the tag parts only, thereby to improve the processing efficiency of the logical language.
Incidentally, evaluation of the tag parts is conducted by examining the tags of the data in a memory read data buffer (DR), as in the paper entitled "Hardware Design of Personal Sequential Type Inference Machine PSI" and collected in the "Proceedings of THE LOGIC PROGRAMMING CONFERENCE '84" concerning the machine .psi., which was published in 1984 from the Institute of New-Generation Computer Technique Development (which is abbreviated into "ICOT"). According to this structure, however, the content in a memory read buffer is renewed if the memory is read. In order to latch a tag to be judged, therefore, operations are required for transferring the contents of a data register to a work file and for reading out again, as necessary, the contents from the work file into the data register. This prolongs the processing time period in case it is necessary to judge a plurality of tags. Since the tags have their bit length fixed at 6 bits, moreover, there arises another defect that the tags cannot be extended.